<?php
/**
 * class FavoritesView
 *  
 */
class FavoritesView {

    public static function getTableWithFavorites($data) {
        $out = '';
        $out.='<div class="span6">
    <h4>' . $data['title'] . '</h4>
    <table class="table">';
        if (!empty($data['pages'])) {
            foreach ($data['pages'] as $page) {
                $out.='<tr><td><a href="' . HTTP_SERVER . $page['path'] . '">' . $page['pagename'] . '</a></td></tr>';
            }
        } else {
            $out.='<tr><td>Нет закладок</td></tr>';
        }
        $out.='</table></div>';
        return $out;
    }

}

?>